/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package cn.ac.iie.di.server;

import cn.ac.iie.di.global.GlobalParas;
import java.util.logging.Level;
import java.util.logging.Logger;

/**
 *
 * @author Austin
 */
public class Monter implements Runnable {
    
    static org.apache.log4j.Logger logger = org.apache.log4j.Logger.getLogger(Monter.class.getName());
    
    @Override
    public void run() {
        while (true) {
            try {
                Thread.sleep(300000);
                logger.info("GlobalParas.videoCount: " + GlobalParas.videoCount.get());
                GlobalParas.videoCount.set(0);
                logger.info("GlobalParas.voiceCount: " + GlobalParas.voiceCount.get());
                GlobalParas.voiceCount.set(0);
                logger.info("GlobalParas.imgCount: " + GlobalParas.imgCount.get());
                GlobalParas.imgCount.set(0);
                logger.info("GlobalParas.translateCount: " + GlobalParas.translateCount.get());
                GlobalParas.translateCount.set(0);
            } catch (InterruptedException ex) {
                logger.error(ex, ex);
            }
        }
    }
    
}
